package com.info.dpunified.common.dataaccess;

import java.sql.ResultSet;
import java.sql.SQLException;

import org.springframework.jdbc.core.ResultSetExtractor;

import com.info.dpunified.common.transfer.DPUStaticData;

public class DPUStaticDataResultSetExtractor implements ResultSetExtractor {

	@Override
	public Object extractData(ResultSet rs) throws SQLException {

		DPUStaticData dpuStaticData = new DPUStaticData();
		
		dpuStaticData.setType(rs.getString("TYPE"));
		dpuStaticData.setCode(rs.getString("CODE"));
		dpuStaticData.setValue(rs.getString("VALUE"));

		return dpuStaticData;
	}

}
